<%@ page contentType="application/vnd.ms-excel;charset=UTF-8"  language="java" import="java.util.*"%>
<%@page import="java.util.*"%>
<%@page import="com.infomanage.po.*"%>
<%@page import="com.infomanage.vo.*"%>
<%@page import="com.infomanage.enums.*"%>
<%@page import="com.infomanage.service.plan.*"%>
<%  response.addDateHeader("Expires", 0);response.setHeader("Pragma","no-cache"); response.setHeader("Cache-Control","no-cache");%>
<%
    request.setCharacterEncoding("UTF-8");
	List<LeaderreservePlanItem>  leaders = LeaderReservePlanService.search(request,response, out);
	int count = 0;
	if(leaders != null){
		count = leaders.size();
	}
	
	// 主界面中查询条件
	String deptId = request.getParameter("deptId");
	if(deptId == null) deptId = "";
	String personId = request.getParameter("personId");
	if(personId == null) personId = "";
	String currentPosition = request.getParameter("currentPosition");
	if(currentPosition == null) currentPosition = "";
	
	// 当前页号
	String currPageNum = request.getParameter("currPageNum");
	if(currPageNum == null) currPageNum = "1";
	
	// 总总页数
	int totalPageSize = LeaderReservePlanService.getPageCount(request,response, out);
%>
<html>
<body rightmargin="0" bottommargin="0" leftmargin="0" topmargin="0" onclick="parent.clickBody();">
<table width="100%" height="100%"  border="1" align="center" cellpadding="0" cellspacing="0" style="table-layout: fixed;background: #ffffff;">
    <tr>
    	<td valign="top">
    		 <table width="100%" height="100%" border="1" cellpadding="0" cellspacing="0" class="tabMain">
    		 	<col width="17%">
    		 	<col width="17%">
    		 	<col width="17%">
    		 	<col width="17%">
    		 	<col width="17%">
    		 	<col width="17%">
         		<tr class="thlist">
         			<td>
			    		姓名 
			    	</td>
			    	<td>
			    		所属单位
			    	</td>
			    	<td>
			    		日期
			    	</td>
			    	<td>
			    		现任职务
			    	</td>
			    	<td>
			    		候选职位
			    	</td>
			    	<td>
			    		备注
			    	</td>
         		</tr>
         		
         		<!-- 输出数据 -->
         		<tr valign="top">
         			<td colspan="6" width="100%">
         				<div style="width: 100%;height: 100%;overflow: auto;">
         					<table class="altColorTable"  cellpadding="0" cellspacing="0" border="1">
    		 	<col width="17%">
    		 	<col width="17%">
    		 	<col width="17%">
    		 	<col width="17%">
    		 	<col width="17%">
    		 	<col width="17%">
				    		 	<%	
				    		 	int i = -1;
				    		 		if(leaders != null) {
				    		 			for(LeaderreservePlanItem leaderItem : leaders) {
				    		 				LeaderreservePlan leader = leaderItem.getBean();
				    		 				Person person = leaderItem.getPerson();
				    		 				i++;
				    		 	%>
         						<tr class="tdlist">
         							<td>
         								<%=person.getName() == null ? "" :person.getName()%>
         							</td>
         							 <td>
         								<%=person.getDeptName()  == null ? "" :person.getDeptName() %>
         							</td>
         							<td>
         								<%=leader.getTimestamp() %>
         							</td>
         							<td>
         								<%=PositionType.valueOf(leader.getCurrentPosition()).title() %>
         							</td>
         							<td>
         								<%=PositionType.valueOf(leader.getCandidatePostion()).title()   %>
         							</td>
         							<td title="<%=leader.getDesciption()%>">
         								<%=leader.getDesciption()%>
         							</td>
         						</tr>
				    		 	
				    		 	<%	
				    		 			}
				    		 		}
				    		 	%>
         					</table>
         				</div>
         			</td>
         		</tr>
         	 </table>
    	</td>
    </tr>
</table>
</body>
</html>
